package com.etl.config;

import ch.qos.logback.classic.spi.ILoggingEvent;
import ch.qos.logback.core.filter.Filter;
import ch.qos.logback.core.spi.FilterReply;
import org.springframework.stereotype.Component;

@Component
public class SampleFilter extends Filter<ILoggingEvent> {


    @Override
    public FilterReply decide(ILoggingEvent event) {
        if (event.getLoggerName().equals("org.pentaho.di.trans.Trans") || event.getLoggerName().equals("org.pentaho.di.job.Job")) {
            return FilterReply.ACCEPT;
        }else{
            return FilterReply.DENY;
        }
    }
}
